﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage/Master.Master" AutoEventWireup="true" CodeBehind="wFrmReporteCompensacion.aspx.cs" Inherits="Crosland.Automotriz.Web.Vehiculos.wFrmReporteCompensacion" %>

<%@ Register Assembly="DevExpress.Web.v13.1, Version=13.1.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxGridView" TagPrefix="dx" %>

<%@ Register Assembly="DevExpress.Web.v13.1, Version=13.1.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxEditors" TagPrefix="dx" %>
<%@ Register assembly="DevExpress.Web.v13.1, Version=13.1.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxRoundPanel" tagprefix="dx" %>
<%@ Register assembly="DevExpress.Web.v13.1, Version=13.1.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxPanel" tagprefix="dx" %>
<%@ Register assembly="DevExpress.Web.v13.1, Version=13.1.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxPopupControl" tagprefix="dx" %>
<%@ Register assembly="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" namespace="Microsoft.Reporting.WebForms" tagprefix="rsweb" %>

<asp:Content ID="Content1" ContentPlaceHolderID="cphMain" runat="server">

<script type="text/javascript">

    function ShowImpresion() {
        popupImpresion.Show();
    }

 </script>


<asp:UpdatePanel ID="upNuevo" runat="server" UpdateMode="Always">
<ContentTemplate>


 <div class="main-header" style="width:100%;">
     <div class="main-titulo">Reporte de Compensación</div>
 </div>

    <div class="content-form">

       <dx:ASPxRoundPanel ID="ASPxRoundPanel1" runat="server" 
            CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
            CssPostfix="Office2010Blue" EnableDefaultAppearance="False" 
            GroupBoxCaptionOffsetX="6px" GroupBoxCaptionOffsetY="-19px" 
            HeaderText="Datos de Consulta" 
            SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" 
            Width="800px">
            <ContentPaddings PaddingBottom="10px" PaddingLeft="9px" PaddingRight="11px" 
                PaddingTop="10px" />
            <HeaderStyle>
            <Paddings PaddingBottom="6px" PaddingLeft="9px" PaddingRight="11px" 
                PaddingTop="3px" />
            </HeaderStyle>
            <PanelCollection>
            <dx:PanelContent runat="server" SupportsDisabledAttribute="True">
            
            <table style="width: 755px">
                <tr>
                <td style="width: 79px">Fecha Inicio:</td>
                <td style="width: 108px">
                    <dx:ASPxDateEdit ID="deFecIni" runat="server" 
                        CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                        CssPostfix="Office2010Blue" Spacing="0" 
                        SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" Width="100px">
                        <CalendarProperties>
                            <HeaderStyle Spacing="1px" />
                        </CalendarProperties>
                        <ButtonStyle Width="13px">
                        </ButtonStyle>
                    </dx:ASPxDateEdit>
                </td>
                <td style="width: 63px">Fecha Fin:</td>
                <td style="width: 110px">
                    <dx:ASPxDateEdit ID="deFecFin" runat="server" 
                        CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                        CssPostfix="Office2010Blue" Spacing="0" 
                        SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" Width="100px">
                        <CalendarProperties>
                            <HeaderStyle Spacing="1px" />
                        </CalendarProperties>
                        <ButtonStyle Width="13px">
                        </ButtonStyle>
                    </dx:ASPxDateEdit>
                </td>
                <td style="width: 56px">Usuario:</td>
                <td>
                    <dx:ASPxComboBox ID="ddlUsuario" runat="server" ValueField="ID"
                        CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                        CssPostfix="Office2010Blue" Spacing="0" 
                        SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css">
                        <LoadingPanelImage Url="~/App_Themes/Office2010Blue/Editors/Loading.gif">
                        </LoadingPanelImage>
                        <LoadingPanelStyle ImageSpacing="5px">
                        </LoadingPanelStyle>
                        <ButtonStyle Width="13px">
                        </ButtonStyle>
                    </dx:ASPxComboBox>
                </td>
                </tr>
                <tr>
                <td style="width: 79px">
                Cliente:
                </td>
                <td colspan="3">
                    <dx:ASPxLabel ID="lblCliente" runat="server" Text="" Width="300px" 
                        Height="20px">
                        <Border BorderStyle="Solid" BorderWidth="1px" />
                    </dx:ASPxLabel>
                    <asp:Label ID="lblIdCliente" runat="server" Visible="False"></asp:Label>
                </td>
                    <td>
                        <dx:ASPxButton ID="btnCliente" runat="server" AutoPostBack="False" 
                            ClientInstanceName="btnCliente" 
                            CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                            CssPostfix="Office2010Blue" 
                            SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" 
                            Width="45px" OnClick="btnCliente_Click">
                            <ClientSideEvents Click="function(s, e) {
	popupCliente.Show();
	e.processOnServer = true;
}" />
                            <BackgroundImage HorizontalPosition="center" ImageUrl="~/Images/three_dots.png" 
                                Repeat="NoRepeat" VerticalPosition="center" />
                        </dx:ASPxButton>
                    </td>
                <td>
                    <dx:ASPxButton ID="btnBuscar" runat="server" Text="Reporte" 
                        AutoPostBack="False" CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                        CssPostfix="Office2010Blue" 
                        SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" 
                        Width="100px" OnClick="btnBuscar_Click">
                    </dx:ASPxButton>
                </td>
                </tr>
            </table>
            
            </dx:PanelContent>
            </PanelCollection>
        </dx:ASPxRoundPanel>




        <br />
        <dx:ASPxPopupControl ID="popupCliente" runat="server" AllowDragging="True" 
            ClientInstanceName="popupCliente" 
            CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
            CssPostfix="Office2010Blue" EnableHotTrack="False" 
            HeaderText="Busqueda de Cliente" Height="119px" Modal="True" 
            PopupHorizontalAlign="WindowCenter" PopupVerticalAlign="WindowCenter" 
            SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" 
            Width="469px" EnableViewState="False">
            <LoadingPanelImage Url="~/App_Themes/Office2010Blue/Web/Loading.gif">
            </LoadingPanelImage>
            <HeaderStyle>
            <Paddings PaddingLeft="7px" />
            </HeaderStyle>
            <LoadingPanelStyle ImageSpacing="5px">
            </LoadingPanelStyle>
            <ContentCollection>
<dx:PopupControlContentControl runat="server" SupportsDisabledAttribute="True">
<table>
                 
                 <tr>
                    <td>
                        <dx:ASPxLabel ID="ASPxLabel8" runat="server" Text="Cliente:" 
                            CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                            CssPostfix="Office2010Blue">
                        </dx:ASPxLabel>
                    </td>
                    <td>
                        <dx:ASPxTextBox ID="txtCliente" runat="server" Width="250px" 
                            ClientInstanceName="txtCliente" 
                            CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                            CssPostfix="Office2010Blue" 
                            SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css">
                        </dx:ASPxTextBox>
                    </td>
                    <td>

                    <asp:UpdatePanel ID="upPopup" runat="server">
                    <ContentTemplate>
                    
                        <dx:ASPxButton ID="btnBuscarCliente" runat="server" Text="Buscar" 
                            CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                            CssPostfix="Office2010Blue" 
                            SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" 
                            ClientInstanceName="btnBuscar" onclick="btnBuscarCliente_Click">
                            <Image Url="~/Images/search.png">
                            </Image>
                        </dx:ASPxButton>

                    </ContentTemplate>
                    </asp:UpdatePanel>

                    </td>
                    
                 </tr>
                

                 </table>

                 <div style="clear:both;height:15px"></div>

                 <dx:ASPxGridView ID="grdClientes" runat="server" 
                         CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                         CssPostfix="Office2010Blue" Width="550px" AutoGenerateColumns="False" 
                         ClientInstanceName="grdClientes" EnableCallBacks="False" 
                         KeyFieldName="ID_CLIENTE" OnPageIndexChanged="grdClientes_PageIndexChanged">
                         <Columns>
                             <dx:GridViewDataTextColumn Caption="Codigo" FieldName="COD_CLIENTE" 
                                 ShowInCustomizationForm="True" VisibleIndex="0">
                                 <HeaderStyle HorizontalAlign="Center" />
                             </dx:GridViewDataTextColumn>
                             <dx:GridViewDataTextColumn Caption="Apellidos y Nombres" 
                                 FieldName="DES_CLIENTE" ShowInCustomizationForm="True" VisibleIndex="1">
                                 <HeaderStyle HorizontalAlign="Center" />
                             </dx:GridViewDataTextColumn>
                             <dx:GridViewDataTextColumn Caption="Nro.Doc." FieldName="NIF" 
                                 ShowInCustomizationForm="True" VisibleIndex="2">
                                 <HeaderStyle HorizontalAlign="Center" />
                             </dx:GridViewDataTextColumn>
                             <dx:GridViewDataTextColumn Caption="Tipo Doc." FieldName="TipoDoc" 
                                 ShowInCustomizationForm="True" VisibleIndex="3">
                                 <HeaderStyle HorizontalAlign="Center" />
                             </dx:GridViewDataTextColumn>
                             <dx:GridViewDataTextColumn Caption="ID" FieldName="ID_CLIENTE" 
                                 ShowInCustomizationForm="True" Visible="False" VisibleIndex="4">
                             </dx:GridViewDataTextColumn>
                         </Columns>
                         <SettingsBehavior AllowFocusedRow="True" AllowSort="False" />
                         <SettingsLoadingPanel Text="Cargando&amp;hellip;" ShowImage="true" />
                         <Images SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css">
                             <LoadingPanelOnStatusBar Url="~/App_Themes/Office2010Blue/GridView/Loading.gif">
                             </LoadingPanelOnStatusBar>
                             <LoadingPanel Url="~/App_Themes/Office2010Blue/GridView/Loading.gif">
                             </LoadingPanel>
                         </Images>
                         <ImagesFilterControl>
                             <LoadingPanel Url="~/App_Themes/Office2010Blue/GridView/Loading.gif">
                             </LoadingPanel>
                         </ImagesFilterControl>
                         <Styles CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                             CssPostfix="Office2010Blue">
                             <Header ImageSpacing="5px" SortingImageSpacing="5px">
                             </Header>
                             <LoadingPanel ImageSpacing="5px">
                             </LoadingPanel>
                         </Styles>
                         <StylesPager>
                             <PageNumber ForeColor="#3E4846">
                             </PageNumber>
                             <Summary ForeColor="#1E395B">
                             </Summary>
                         </StylesPager>
                         <StylesEditors ButtonEditCellSpacing="0">
                             <ProgressBar Height="21px">
                             </ProgressBar>
                         </StylesEditors>
                     </dx:ASPxGridView>
                     
                     <div style="clear:both;height:15px"></div>

                     <center>
                     <table>
                     <tr>
                        <td>
                            <dx:ASPxButton ID="btnAceptar" runat="server" Text="Aceptar" 
                                AutoPostBack="False" CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                                CssPostfix="Office2010Blue" 
                                SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" 
                                OnClick="btnAceptar_Click">
                                <ClientSideEvents Click="function(s, e) {
	popupCliente.Hide();
}" />
                                <Image Url="~/Images/ok.png">
                                </Image>
                            </dx:ASPxButton>
                        </td>
                        <td></td>
                        <td>
                            <dx:ASPxButton ID="btnCancelar" runat="server" Text="Cancelar" 
                                AutoPostBack="False" CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
                                CssPostfix="Office2010Blue" 
                                SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css">
                                <ClientSideEvents Click="function(s, e) {
	popupCliente.Hide();
}" />
                                <Image Url="~/Images/cancel.png">
                                </Image>
                            </dx:ASPxButton>
                        </td>
                     </tr>
                     </table>
                     </center>



</dx:PopupControlContentControl>
</ContentCollection>
        </dx:ASPxPopupControl>
        
                 


        <dx:ASPxPopupControl ID="popupImpresion" runat="server" AllowDragging="True" 
            ClientIDMode="Static" ClientInstanceName="popupImpresion" 
            CloseAction="CloseButton" 
            CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" 
            CssPostfix="Office2010Blue" EnableHotTrack="False" 
            HeaderText="Vista Previa / Imprimir" Modal="True" 
            PopupHorizontalAlign="WindowCenter" PopupVerticalAlign="WindowCenter" 
            SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" Width="800px">
            <LoadingPanelImage Url="~/App_Themes/Office2010Blue/Web/Loading.gif">
            </LoadingPanelImage>
            <HeaderStyle>
            <Paddings PaddingLeft="7px" />
            </HeaderStyle>
            <LoadingPanelStyle ImageSpacing="5px">
            </LoadingPanelStyle>
            <ContentCollection>
<dx:PopupControlContentControl runat="server" SupportsDisabledAttribute="True">
    <rsweb:ReportViewer ID="rvPopupReporte" runat="server" BackColor="#F2F2F2" 
        Font-Names="Verdana" Font-Size="8pt" Height="420px" 
        InteractiveDeviceInfos="(Collection)" WaitMessageFont-Names="Verdana" 
        WaitMessageFont-Size="14pt" Width="100%">
    </rsweb:ReportViewer>
                </dx:PopupControlContentControl>
</ContentCollection>
        </dx:ASPxPopupControl>




    </div>

    </ContentTemplate>
    </asp:UpdatePanel>


    </asp:Content>
